package com.example.minefieldkeepercloud.adapter;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;

import com.example.minefieldkeepercloud.R;

import com.example.minefieldkeepercloud.bean.DailyPowerDetailBean;
import com.king.base.adapter.ViewHolderAdapter;
import com.king.base.adapter.holder.ViewHolder;

import java.util.List;

public class DailyPowerDetailAdapter extends ViewHolderAdapter<DailyPowerDetailBean.DataBean> {
    private Context context;

    public DailyPowerDetailAdapter(Context context, List<DailyPowerDetailBean.DataBean> listData) {
        super(context, listData);
        this.context = context;
    }

    @Override
    public View buildConvertView(LayoutInflater layoutInflater, DailyPowerDetailBean.DataBean string, int position) {
        return inflate(R.layout.adapter_dailypowerdetail);
    }

    @Override
    public void bindViewDatas(ViewHolder holder, DailyPowerDetailBean.DataBean bean, final int position) {
        holder.setText(R.id.tv_date, bean.getYearMDH());
        holder.setText(R.id.tv_title, bean.getFactoryName());
        holder.setText(R.id.tv_name, bean.getFullName());
        holder.setText(R.id.tv_1, bean.getYszxgs()+"");
        holder.setText(R.id.tv_2, bean.getSjkjgs()+"");
        holder.setText(R.id.tv_3, bean.getSjzxgs()+"");
        holder.setText(R.id.tv_4, bean.getPjsl()+"");
        holder.setText(R.id.tv_5, bean.getDbsl()+"");
        holder.setText(R.id.tv_6, bean.getSjsl()+"");
        holder.setText(R.id.tv_7, bean.getDbc()+"");
        holder.setText(R.id.tv_8, bean.getBzl()+"");
        holder.setText(R.id.tv_9, bean.getDbl()+"");
        holder.setText(R.id.tv_10, bean.getWsj_new()+"");
        holder.setText(R.id.tv_11, bean.getYsj()+"");
        holder.setText(R.id.tv_12, bean.getBf()+"");
        holder.setText(R.id.tv_13, bean.getFx()+"");
    }
}
